import Http from "@/http";

export function saveApi(params:any) {
    return params.id ? Http.post('article/category/update', params) : Http.post('article/category/add', params)
}


export function deleteApi(id) {
    return Http.post('article/category/delete', {id: id})
}


export function listApi() {
    return Http.get('article/category/list')
}

export async function optionsApi() {
    const r = await Http.get('article/category/options')
    return r.data
}